<template>
    <view class="TripartiteGames">
        <web-view :src="url" />
    </view>
</template>
<script>
export default {
    name: "TripartiteGames",
    mixins: [],
    props: {},
    data() {
        return {
            url: "",
            user: {},
        };
    },
    computed: {},
    watch: {},
    mounted() {},
    async onShow() {
        //刷新用户信息
    },
    async onLoad(options) {
        let item = JSON.parse(options.item);
        await uni.request({
            url: "/wanlshop/user/refresh",
            method: "POST",
            success: (res) => {
                console.log(res, "[[[[[[[[[[[]]]]]]]]]]]");
                this.user = res.res.data.userinfo;
                console.log(this.user, "个人信息");
                // this.url =
                //     "https://ss.lusebaidu.com/index.php?aid=1&uid=1&nickname=admin&avatar=https://impresscity.ascetic.top/uploads/20240723/ba3395060959f97b8314f712855e3a29.jpg";
                // #ifdef MP
                this.url =
                    item.jump_url +
                    "?aid=1&uid=" +
                    this.user.user_id +
                    "&nickname=" +
                    this.user.nickname +
                    "&avatar=" +
                    this.user.avatar;

                // #endif

                // #ifdef H5
                this.url =
                    item.jump_url +
                    "?aid=1&uid=" +
                    this.user.user_id +
                    "&nickname=" +
                    this.user.nickname +
                    "&avatar=" +
                    this.user.avatar;

                // #endif
                console.log(this.url, "lijing ");
                // // #ifdef H5
                // // this.url = JSON.parse(options.url);
                // // #endif
                // this.url = decodeURIComponent(options.url);
                // // #ifdef MP
                // // #endif
                // console.log(decodeURIComponent(options.url), "lijing ");
            },
        });
    },
    methods: {},
};
</script>
<style lang="scss" scoped></style>
